package com.d3works.apps.bpm.service;

import com.d3works.apps.bpm.db.WkfProcessConfig;
import com.d3works.db.Model;
import com.d3works.exception.D3worksException;
import java.util.Map;
import org.camunda.bpm.model.xml.instance.ModelElementInstance;

public interface WkfCommonService {

  public WkfProcessConfig findCurrentProcessConfig(Model model);

  public WkfProcessConfig findOldProcessConfig(Model model);

  public Object evalExpression(Map<String, Object> varMap, String expr);

  public Map<String, Object> createVariables(Map<String, Object> modelMap);

  public String getVarName(Object model);

  public Object findRelatedRecord(Model model, String path) throws D3worksException;

  public Model addProperties(
      Map<String, String> propertyMap, Model model, ModelElementInstance element);
}
